import java.util.Scanner;

public class Mark {
    private static double ChineseMark;
    private static double MathMark;
    private static double EnglishMark;

    public static void ChineseMarkJudge(double a) throws MarkMistake {
        try {
            ChineseMark = a;
        } catch (Exception e) {
            e.printStackTrace();
            throw new MarkMistake("The mark should be a NUMBER");
        }
        if (a < 0 || a > 100) {
            throw new MarkMistake("Print error in Math, the mark range should be 0~100");
        }
        return;
    }

    public static double getChineseMark(){
        return ChineseMark;
    }
    public static void MathMarkJudge(double b) throws MarkMistake {
        Scanner input = new Scanner(System.in);
        try {
            MathMark = b;
        } catch (Exception e) {
            e.printStackTrace();
            throw new MarkMistake("The mark should be a NUMBER");
        }
        if (b < 0 || b > 100) {
            throw new MarkMistake("Print error in Math, the mark range should be 0~100");
        }
        return;
    }
    public static double getMathMark(){
        return MathMark;
    }
    public static void EnglishMarkJudge(double c) throws MarkMistake {
        Scanner input = new Scanner(System.in);
        try {
            EnglishMark = c;
        } catch (Exception e) {
            e.printStackTrace();
            throw new MarkMistake("The mark should be a NUMBER");
        }
        if (c < 0 || c > 100) {
            throw new MarkMistake("Print error in English, the mark range should be 0~100");
        }
        return;
    }
    public static double getEnglishMark(){
        return EnglishMark;
    }
}
